DotGraph Example

Testing example created in the Zephyr project using pyreverse from the pylint project. The file Example/packages_zephyr.dot was generated by:

pyreverse -my -A -o dot -p zephyr ../zephyr/**/**.py

Rendered using pyreverse

DotGraph Example


In [1]:
from dotgraph import *

In [2]:
dg = DotGraph('./Example/packages_zephyr.dot')

In [3]:
dg


Out[3]:

In [4]:
help(DotGraph)


Help on class DotGraph in module dotgraph:

class DotGraph(__builtin__.object)
 |  Class that returns various representations of the directed graph
 |  in a 'dot' file. This includes converting to NetworkX graph object,
 |  Python dictionary, JSON, and HTML with d3.js rendering (which can
 |  be displayed inline in an IPython/Jupyter notebook).
 |  
 |  Methods defined here:
 |  
 |  __init__(self, infile, template=None)
 |      Initialize DotGraph
 |      
 |      Args:
 |          infile (str):       Input file in dot format
 |          template (str):     Input file for HTML template
 |      
 |      Returns:
 |          new DotGraph instance
 |  
 |  render(self)
 |      Returns IPython display representation
 |  
 |  ----------------------------------------------------------------------
 |  Data descriptors defined here:
 |  
 |  __dict__
 |      dictionary for instance variables (if defined)
 |  
 |  __weakref__
 |      list of weak references to the object (if defined)
 |  
 |  dict
 |      Returns dictionary representation
 |  
 |  graph
 |      Returns NetworkX graph representation
 |  
 |  html
 |      Returns HTML representation
 |  
 |  json
 |      Returns JSON representation